package com.macro.mall.controller;

import com.macro.mall.common.api.CommonResult;
import com.macro.mall.dto.HomeContentResult;
import com.macro.mall.service.UmsHomeService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.v3.oas.annotations.tags.Tag;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

/**
 * @Author：MinxiaoHao
 * @Description:
 * @name：HomeController
 * @Date：2024/10/18 10:13
 */
@RestController
@RequestMapping("/home")
@Api(tags = "HomeController")
@Tag(name = "HomeController", description = "首页内容管理")
public class UmsHomeController {
    @Autowired
    private UmsHomeService homeService;

    /**
     * 首页内容信息展示
     */
    @ApiOperation("首页内容信息展示")
    @RequestMapping(value = "/content", method = RequestMethod.GET)
    public CommonResult<HomeContentResult> content() {
        HomeContentResult homeContentResult=homeService.content();
        return CommonResult.success(homeContentResult);
    }


}
